#ifndef _INDEX_H_
#define _INDEX_H_
#include "ast/sliceType.h"
#include "ast/exprType.h"
class IVisitor;
class Index;
typedef QSharedPointer<Index> IndexPtr;

class Index: public sliceType
{
public:
    explicit Index(const exprTypePtr& value, int nodeId=-1);
    virtual ~Index();
    
    
    exprTypePtr value();
    void setValue(const exprTypePtr& value);
    
    
    virtual QString type() const;
    virtual QString toString() const;
    virtual void accept(IVisitor* visitor, const SimpleNodePtr& node);
    virtual void traverse(IVisitor* visitor);
private:
    exprTypePtr _value;
};




#endif